// 分页获取
// 养老设施服务
const serviceFacModel = (request) => {
	return {
		// 政策文件

		// 增加
		dpPolicyDocument_add(query = {}) {
			return request(`/bussiness/dpPolicyDocument/add`, {
				method: 'post',
				data: query,
			})
		},
		// 采集
		view_dpPolicyDocument_gather(query = {}) {
			return request(`/bussiness/dpPolicyDocument/gather`, {
				method: 'post',
				data: query,
			})
		},
		// 分页获取列表
		dpPolicyDocument_page(query = {}) {
			return request(`/bussiness/dpPolicyDocument/page`, {
				method: 'post',
				data: query,
			})
		},
		// 编辑
		dpPolicyDocument_edit(query = {}) {
			return request(`/bussiness/dpPolicyDocument/edit`, {
				method: 'post',
				data: query,
			})
		},
		// 通过id查看详情
		dpPolicyDocument_view(id) {
			return request(`/bussiness/dpPolicyDocument/${id}`, {
				method: 'get',
			})
		},
		// 导出
		dpPolicyDocument_export(query = {}) {
			return request(`/bussiness/dpPolicyDocument/export`, {
				method: 'post',
				data: query,
			})
		},
		// 通过id删除
		dpPolicyDocument_del(ids) {
			return request(`/bussiness/dpPolicyDocument/del`, {
				method: 'post',
				data: {
					batchesDel: ids,
				},
			})
		},
		// 下载模版
		dpPolicyDocument_downloadTemplate(query = {}) {
			return request(`/bussiness/dpPolicyDocument/downloadTemplate`, {
				method: 'post',
				responseType: 'blob',
				data: query,
			})
		},
		// 导入
		dpPolicyDocument_import(query = {}, onUploadProgress) {
			return request(`/bussiness/dpPolicyDocument/import`, {
				method: 'post',
				headers: {
					'Content-Type': 'multipart/form-data; boundary=something',
				},
				onUploadProgress,
				data: query,
			})
		},

		// 养老资讯
		// 全字段查询
		view_dpNewsInfo_search(query = {}) {
			return request(`/bussiness/dpNewsInfo/search`, {
				method: 'post',
				data: query,
			})
		},
		// 采集
		view_dpNewsInfo_gather(query = {}) {
			return request(`/bussiness/dpNewsInfo/gather`, {
				method: 'post',
				data: query,
			})
		},
		// 增加
		dpNewsInfo_add(query = {}) {
			return request(`/bussiness/dpNewsInfo/add`, {
				method: 'post',
				data: query,
			})
		},
		// 分页获取列表
		dpNewsInfo_page(query = {}) {
			return request(`/bussiness/dpNewsInfo/page`, {
				method: 'post',
				data: query,
			})
		},
		// 编辑
		dpNewsInfo_edit(query = {}) {
			return request(`/bussiness/dpNewsInfo/edit`, {
				method: 'post',
				data: query,
			})
		},
		// 通过id查看详情
		dpNewsInfo_view(id) {
			return request(`/bussiness/dpNewsInfo/${id}`, {
				method: 'get',
			})
		},
		// 导出
		dpNewsInfo_export(query = {}) {
			return request(`/bussiness/dpNewsInfo/export`, {
				method: 'post',
				data: query,
			})
		},
		// 通过id删除
		dpNewsInfo_del(ids) {
			return request(`/bussiness/dpNewsInfo/del`, {
				method: 'post',
				data: {
					batchesDel: ids,
				},
			})
		},
		// 下载模版
		dpNewsInfo_downloadTemplate(query = {}) {
			return request(`/bussiness/dpNewsInfo/downloadTemplate`, {
				method: 'post',
				responseType: 'blob',
				data: query,
			})
		},
		// 导入
		dpNewsInfo_import(query = {}, onUploadProgress) {
			return request(`/bussiness/dpNewsInfo/import`, {
				method: 'post',
				headers: {
					'Content-Type': 'multipart/form-data; boundary=something',
				},
				onUploadProgress,
				data: query,
			})
		},
		/*
			一站办的新闻资讯新增和详情
		*/ 
		// 新增
		view_dpNewsInfoBsc_gather(query = {}) {
			return request(`/application/dpNewsInfoBsc/gather`, {
				method: 'post',
				data: query,
			})
		},
		// 通过id查看详情
		view_dpNewsInfoBsc_view(id) {
			return request(`/application/dpNewsInfoBsc/${id}`, {
				method: 'get',
			})
		},
	}
}
export default ({ request }: any) => ({
	...serviceFacModel(request),
})
